// 例子19

(function () {
    var timer = setTimeout(function() {
        delay();
    }, 5000);
})();

console.log('----------------------------------');

(function () {
    var timer = setTimeout(delay, 5000);
})();